<?php
// +----------------------------------------------------------------------
// | CatchAdmin [Just Like ～ ]
// +----------------------------------------------------------------------
// | Copyright (c) 2017~{$year} http://catchadmin.com All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( https://github.com/yanwenwu/catch-admin/blob/master/LICENSE.txt )
// +----------------------------------------------------------------------
// | Author: JaguarJack [ njphper@gmail.com ]
// +----------------------------------------------------------------------

// you should use `$router`
/* @var think\Route $router */

$router->group(function () use ($router) {
    $router->post("authentication", "\catchAdmin\apipatient\controller\User@authentication");
});


$router->group(function () use ($router) {

    $router->get('get_fw_class', '\catchAdmin\apipatient\controller\Fw@get_fw_class');
    $router->get('get_fw_pack', '\catchAdmin\apipatient\controller\Fw@get_fw_pack');
    $router->get('get_fw_content', '\catchAdmin\apipatient\controller\Fw@get_fw_content');
    $router->get('get_fw_content_detail', '\catchAdmin\apipatient\controller\Fw@get_fw_content_detail');
    $router->get('get_ed_class', '\catchAdmin\apipatient\controller\Ed@get_ed_class');
    $router->get('get_ed_list', '\catchAdmin\apipatient\controller\Ed@get_ed_list');
    $router->get('get_ed_my', '\catchAdmin\apipatient\controller\Ed@get_ed_my');
    $router->get('get_ed_jkys', '\catchAdmin\apipatient\controller\Ed@get_ed_jkys');
    $router->get('get_ed_detail', '\catchAdmin\apipatient\controller\Ed@get_ed_detail');
    $router->get('get_my_ed_detail', '\catchAdmin\apipatient\controller\Ed@get_my_ed_detail');
    $router->post('ed/inhospital_ed_sign', '\catchAdmin\apipatient\controller\Ed@inhospital_ed_sign');
    $router->get('get_hzd_satisfied_quest', '\catchAdmin\apipatient\controller\Ed@get_hzd_satisfied_quest');

    $router->get('get_sf_list', '\catchAdmin\apipatient\controller\Follow@get_sf_list');
    $router->get('get_hzd_message_list', '\catchAdmin\apipatient\controller\Follow@get_hzd_message_list');

    $router->get('get_my_case', '\catchAdmin\apipatient\controller\Healthy@get_my_case');
    $router->get('get_my_case_detail', '\catchAdmin\apipatient\controller\Healthy@get_my_case_detail');
    $router->get('get_my_case_report', '\catchAdmin\apipatient\controller\Healthy@get_my_case_report');
    $router->get('get_time_case_report', '\catchAdmin\apipatient\controller\Healthy@get_time_case_report');
    $router->post('healthy/uploadimg', '\catchAdmin\apipatient\controller\Healthy@uploadimg');
    $router->post('healthy/delimg', '\catchAdmin\apipatient\controller\Healthy@delimg');

    $router->get('get_my_info', '\catchAdmin\apipatient\controller\My@get_my_info');
    $router->get('get_my_family', '\catchAdmin\apipatient\controller\My@get_my_family');
    $router->get('get_my_family_detailed', '\catchAdmin\apipatient\controller\My@get_my_family_detailed');
    $router->get('get_hzd_relation', '\catchAdmin\apipatient\controller\My@get_hzd_relation');
    $router->get('get_hzd_source', '\catchAdmin\apipatient\controller\My@get_hzd_source');
    $router->post('my/my_family_add', '\catchAdmin\apipatient\controller\My@my_family_add');
    $router->post('my/my_family_up', '\catchAdmin\apipatient\controller\My@my_family_up');
    $router->post('my/my_family_del', '\catchAdmin\apipatient\controller\My@my_family_del');
    $router->get('contact_customer_service', '\catchAdmin\apipatient\controller\My@contact_customer_service');
    $router->get('get_hzd_myd_list', '\catchAdmin\apipatient\controller\Myd@get_hzd_myd_list');
    $router->post('myd/push_hzd_questionnaire', '\catchAdmin\apipatient\controller\Myd@push_hzd_questionnaire');
    $router->get("AnswerDetail/<id>", "\catchAdmin\apipatient\controller\Answer@getAnswer");
    $router->get("GetMySatisAnswers", "\catchAdmin\apipatient\controller\Myd@getMyAnswer");
    $router->get("getMyServicesSigned", "\catchAdmin\apipatient\controller\Fw@getMyServicesSigned");
    $router->post("HealthDiary", "\catchAdmin\apipatient\controller\HealthDiary@save");
    $router->post("GetHealthDiary", "\catchAdmin\apipatient\controller\HealthDiary@index");
    $router->any("GetLastHealthDiary", "\catchAdmin\apipatient\controller\HealthDiary@getLastHealthRecord");
    $router->any("GetHealRecordDetail", "\catchAdmin\apipatient\controller\HealthDiary@getHealRecordDetail");
    $router->any("getHealRecordList", "\catchAdmin\apipatient\controller\HealthDiary@getHealRecordList");
    $router->any("GetContractDoctorsList", "\catchAdmin\apipatient\controller\My@accessToContractedDoctors");
    $router->any("GetMyContractList", "\catchAdmin\apipatient\controller\My@getMyContractList");
    $router->any("GetProcessPath", "\catchAdmin\apipatient\controller\DiseasePath@index");
    $router->any("GetProcessList", "\catchAdmin\apipatient\controller\DiseasePath@processList");
    $router->any("GetLatestTask", "\catchAdmin\apipatient\controller\DiseasePath@getLatestTask");
    $router->any("GetPatientVisitPlan", '\catchAdmin\visitPlan\controller\VisitPlanDetail@patientVisitPlan');
    $router->get('GetMyPath',"\catchAdmin\apipatient\controller\DiseasePath@getMyPath");
    $router->post('GetMyPathDetail',"\catchAdmin\apipatient\controller\DiseasePath@getMyPathDetail");

    //获取医生端未读消息数
    $router->post('hzdUnreadMessageNum', '\catchAdmin\apipatient\controller\Follow@getHzdUnreadMessageNum');
    //清除医生端未读消息
    $router->post('cleanHzdUnreadMessage', '\catchAdmin\apipatient\controller\Follow@cleanHzdUnreadMessage');
    //阅读消息
    $router->post('readHzdMessage', '\catchAdmin\apipatient\controller\Follow@readHzdMessage');
    //签约的随访包
    $router->any('getHzdSignedServicePack', '\catchAdmin\apipatient\controller\Fw@getHzdSignedServicePack');
    //签约的随访包详情
    $router->any('getHzdSignedServicePackDetails', '\catchAdmin\apipatient\controller\Fw@getHzdSignedServicePackDetails');
    $router->any('putNodeMessage', '\catchAdmin\apipatient\controller\NodeMessage@pushContent');
    $router->get('getInfoByTaskId/:taskId', '\catchAdmin\apipatient\controller\NodeMessage@getInfoByTaskId');

    //用药提醒
    $router->any('getMedicineBox', '\catchAdmin\apipatient\controller\MedicationReminder@getMedicineBox');
    $router->any('indexReminder', '\catchAdmin\apipatient\controller\MedicationReminder@indexReminder');
    $router->post('addReminder', '\catchAdmin\apipatient\controller\MedicationReminder@addReminder');
    $router->post('MedicationOperations', '\catchAdmin\apipatient\controller\MedicationReminder@MedicationOperations');
    $router->any('getHzdDrug', '\catchAdmin\apipatient\controller\MedicationReminder@getHzdDrug');
    $router->any('getHzdReminderUnit', '\catchAdmin\apipatient\controller\MedicationReminder@getHzdReminderUnit');

    //商城
    //分类列表
    $router->any('getShoppingClassify', '\catchAdmin\apipatient\controller\Shopping@getClassify');
    //产品列表
    $router->any('getHzdShoppingProduct', '\catchAdmin\apipatient\controller\Shopping@getHzdShoppingProduct');
    //商品详情
    $router->post('getHzdShoppingGoods', '\catchAdmin\apipatient\controller\Shopping@getHzdShoppingGoods');

    //随访消息
    $router->any('followMessage', '\catchAdmin\apipatient\controller\Follow@followMessage');
})->middleware([\app\middleware\DoctorCheck::class]);
